#include<bits/stdc++.h>
#define M 100010
#define rep(x,y,z) for (int x=y;x<=z;x++)
using namespace std;
int n,t,tot;
int a[M],b[M],c[M];


int main(){
    memset(b,0,sizeof(b));
    freopen("duel.in","r",stdin);
    freopen("duel.out","w",stdout);
    ios::sync_with_stdio(0);
    cin.tie(0),cout.tie(0);
    cin>>n;
    rep(i,1,n){
        int t;
        cin>>t;
        if (b[t]==0) a[++tot]=t;
        b[t]++,c[t]++;
    }

    sort(a+1,a+tot+1);


    rep(i,1,tot){

        rep(j,i+1,tot){
            if (b[a[i]]>=c[a[j]]){

                b[a[i]]-=c[a[j]];
                c[a[j]]=0;
            }
            else{
                c[a[j]]-=b[a[i]];
                b[a[i]]=0;
                break;
            }
        }

    }
    int ans=0;
    for (int i=1;i<=tot;i++){
        ans+=b[a[i]];
    }
    cout<<ans;


}



